<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>js eval()</title>

    <script type="text/javascript">
        var x = eval(prompt("Type a number",0));
        alert(x);

        console.log(eval("2 + 3"));
    </script>

</head>
<body>
    
</body>
</html>